import request from '@/utils/request'

/**
 *
 * @returns 获取用户频道
 */
export const reqGetChannels = () => {
  return request({
    method: 'get',
    url: '/v1_0/user/channels'
  })
}

/**
 *
 * @returns 获取全部频道
 */
export const reqGetAllChannels = () => {
  return request({
    method: 'get',
    url: '/v1_0/channels'
  })
}

export const reqSetChannels = (channels) => {
  return request({
    method: 'put',
    url: '/v1_0/user/channels',
    data: {
      channels
    }
  })
}
